<?php


namespace Trawind\Remotes\Repositories\Account\Account;


use Trawind\Basics\Enums\ServiceDomain;
use Trawind\Remotes\BaseRepository;
use Trawind\Remotes\Contracts\Repositories\Account\Account\CompanyRepository;

class CompanyRepositoryEloquent extends BaseRepository implements CompanyRepository
{

    public $baseRoute = '/organization/companys';


    public function __construct()
    {
        $this->domain = ServiceDomain::ACCOUNT_DOMAIN();
    }


    public function all($columns = ['*'])
    {
        return $this->setUrl($this->baseRoute)->result();
    }

    public function create(array $attributes)
    {
        // TODO: Implement create() method.
    }

    public function update(array $attributes, $id)
    {
        // TODO: Implement update() method.
    }

    /**
     * @param $id
     * @param array $columns
     * @return mixed|null
     * @throws \GuzzleHttp\Exception\GuzzleException
     */
    public function find($id, $columns = ['*'])
    {
        return $this->setUrl($this->baseRoute . '/' . $id)->result();
    }

    public function updateCompany(array $params, int $id)
    {
        // TODO: Implement updateCompany() method.
    }

    public function saveCompany(array $params)
    {
        // TODO: Implement saveCompany() method.
    }

    public function deleteCompany(array $id)
    {
        // TODO: Implement deleteCompany() method.
    }

    public function isCancellation(array $id)
    {
        // TODO: Implement isCancellation() method.
    }

    public function treatmentState(array $ids, $companyStatus)
    {
        // TODO: Implement treatmentState() method.
    }

    public function tree(array $data, $parentId = 0)
    {
        // TODO: Implement tree() method.
    }
}
